package cn.paul.wechatshop.exception;

import cn.paul.wechatshop.common.Const;
import org.springframework.web.bind.annotation.ControllerAdvice;

/**
 * @author 徐凌峰
 * @date 2017/12/13 0013
 */

public class WechatshopException extends RuntimeException {

    private Integer code;


    public WechatshopException(Const.ResultEnum resultEnum) {
        super(resultEnum.getMsg());
        this.code = resultEnum.getCode();
    }

    public WechatshopException(Integer code, String message) {
        super(message);
        this.code=code;
    }
}

